package com.example.codegen;

public class Parameter implements AstNode {
    public Type parameterType;
    public String parameterName;

    public Parameter(Type type, String s) {
        this.parameterType = type;
        this.parameterName = s;
    }

    public String toJava() {
        return parameterType.toJava() + " " + parameterName;
    }

    public String toGo() {
        return parameterName + " " + parameterType.toGo();
    }

    @Override
    public String toJs() {
        return parameterName;
    }

    @Override
    public String toCSharp() {
        return parameterType.toCSharp() + " " + parameterName;
    }

    @Override
    public String toCJ() {
        return  parameterName + ": " + parameterType.toCJ();
    }
}
